#jenkins
#apk
echo '开始执行脚本'
echo '切换apk仓库源到阿里云'
rm -f /etc/apk/repositories
touch /etc/apk/repositories
chmod 777 /etc/apk/repositorie
echo "
http://mirrors.aliyun.com/alpine/v3.9/main/
http://mirrors.aliyun.com/alpine/v3.9/community/">/etc/apk/repositories
#update
apk update
echo '切换成功'

#
echo '安装gradle,maven,npm 环境'
apk add gradle maven npm
gradle -v
mvn -v
npm -v
echo '安装成功'
echo 'npm添加国内源 安装cnpm'
npm install cnpm -g --registry=https://registry.npm.taobao.org
echo 'cnpm 安装成功'
ehco '脚本结束'

